# Contributor: Thomas Kienlen <kommander@laposte.net>
# Maintainer: Thomas Kienlen <kommander@laposte.net>
pkgname=curtail
_pkgname=Curtail
pkgver=1.3.0
pkgrel=0
pkgdesc="Simple & useful image compressor"
url="https://github.com/Huluti/Curtail"
arch="noarch"
license="GPL-3.0-or-later"
depends="optipng pngquant jpegoptim libwebp py3-gobject3"
makedepends="python3 meson gettext appstream-glib py3-gobject3-dev"
source="
	https://github.com/Huluti/Curtail/archive/$pkgver/curtail-$pkgver.tar.gz
	fix-bindtextdomain.patch
	"
subpackages="$pkgname-lang"

builddir="$srcdir/$_pkgname-$pkgver"

build() {
	abuild-meson . build
	meson compile ${JOBS:+-j ${JOBS}} -C build
}

check() {
	meson test --no-rebuild --print-errorlogs -C build
}

package() {
	DESTDIR="$pkgdir" meson install --no-rebuild -C build
}

sha512sums="
5e87b690ba9915280aa84d1ec42e1814f558eb1db1c6d6f4f8247503f60f10705fccc350192e85a76976298f17621392a8eadf75ed0136dea4f7ec93080a99bd  curtail-1.3.0.tar.gz
1f6e43b3097fb808996553a1abc95ef10637bd0b1d7d51de451411509a6f1407af7cb7f593113c33d7818aaed78fe164dc3714f1851f74d24c97157d9053642e  fix-bindtextdomain.patch
"
